package com.dabaozhan.modules.wx_app.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.dabaozhan.modules.wx_app.dao.SupplierUserMapper;
import com.dabaozhan.modules.wx_app.entity.SupplierUserEntity;
import com.dabaozhan.modules.wx_app.entity.SupplierUserQueryEntitiy;
import com.dabaozhan.modules.wx_app.service.SupplierUserService;

@Service("supplierUserService")
public class SupplierUserServiceImpl implements SupplierUserService{
	
	@Autowired
	private SupplierUserMapper supplierUserMapper;

	@Override
	public List<SupplierUserEntity> getSupplierUserForPage(SupplierUserQueryEntitiy entity) {
		return supplierUserMapper.getSupplierUserForPage(entity);
	}

	@Override
	public int addSupplierUser(SupplierUserEntity entity) {
		return supplierUserMapper.addSupplierUser(entity);
	}

	@Override
	public SupplierUserEntity getSupplierUserByPhone(String phone,String packerId) {
		return supplierUserMapper.getSupplierUserByPhone(phone,packerId);
	}

	@Override
	public int deleteSupplierUser(String userId,String packerId) {
		return supplierUserMapper.deleteSupplierUser(userId,packerId);
	}

	@Override
	public int updateSupplierUser(SupplierUserEntity supplierUser) {
		return supplierUserMapper.updateSupplierUser(supplierUser);
	}

	@Override
	public long getCountForPage(SupplierUserQueryEntitiy entity) {
		return supplierUserMapper.getCountForPage(entity);
	}

}
